import 'package:amoy_ticket/utils/object_util.dart';
import 'package:cached_network_image/cached_network_image.dart';
import 'package:card_swiper/card_swiper.dart';
import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';

class MovieTabBarOne extends StatefulWidget {
  MovieTabBarOne({Key? key}) : super(key: key);

  @override
  _MovieTabBarOneState createState() => _MovieTabBarOneState();
}

class _MovieTabBarOneState extends State<MovieTabBarOne> {
  List _boxOfficeHeadList = [
    {'order': '1', 'name': '失控玩家', 'number': '1.7亿'},
    {'order': '2', 'name': '怒火·重案', 'number': '6922.7万'},
    {'order': '3', 'name': '明日之战', 'number': '6769.8万'},
    {'order': '4', 'name': '妈妈的神奇小子', 'number': '1128.1万'},
    {'order': '5', 'name': '夏日友晴天', 'number': '1025.4万'},
    {'order': '6', 'name': '陪你很久很久', 'number': '997.2万'},
    {'order': '7', 'name': '白蛇2:青蛇劫起', 'number': '998.2万'},
    {'order': '8', 'name': '盛夏未来', 'number': '580.3万'},
    {'order': '9', 'name': '不期而遇的夏天', 'number': '369.9万'},
    {'order': '10', 'name': '最后一间房', 'number': '295.3万'},
  ];

  List boxOfficeList = [
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image1.jpg',
      'name': '长津湖',
      'score': '9.5',
      'numberOfPeopleToAppraise': '124.1万',
      'director': '陈凯歌、徐克、林超贤',
      'performer': '吴京、易烊千玺、段奕宏、朱亚文',
      'filmGrade': '2D IMAX',
      'status': '购票',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image2.jpg',
      'name': '不速来客',
      'score': '',
      // 'numberOfPeopleToAppraise': '36.8万',
      'director': '刘翔',
      'performer': '范伟、窦骁、张颂文、朱珠',
      'filmGrade': '2D IMAX',
      'status': '购票',
      'label': '三人卷入隐秘悬案'
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image3.jpg',
      'name': '沙丘',
      'score': '',
      'director': '丹尼斯·维伦纽瓦',
      'performer': '提莫西、查拉梅 丽贝卡',
      'filmGrade': '3D IMAX',
      'status': '购票',
      'label': '科幻神作'
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image4.jpg',
      'name': '第一炉香',
      'director': '李骏',
      'performer': '朱一龙 黄志忠 陈数 焦俊艳 王戈',
      'filmGrade': '2D IMAX',
      'status': '预售',
      'numberWantSee': '109，671',
      'releaseTime': '今天上映',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image5.jpg',
      'name': '极盗行动',
      'score': '',
      'director': '埃列尔·维诺格拉德',
      'performer': '古勒莫·法兰塞拉',
      'status': '预售',
      'releaseTime': '下周日',
      'label': '瞒天过海抢劫案'
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image6.jpg',
      'name': '我和我的父辈',
      'score': '9.5',
      'numberOfPeopleToAppraise': '42.9',
      'director': '吴京 章子怡 徐峥 沈腾',
      'performer': '吴京 章子怡 徐峥 沈腾 吴磊',
      'filmGrade': '2D 中国巨幕',
      'status': '购票',
      'label': '传承奋斗精神'
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image7.jpg',
      'name': '兰心大剧院',
      'score': '7.7',
      'numberOfPeopleToAppraise': '5.4万',
      'director': '娄烨',
      'performer': '巩俐 赵又廷 小田切让 帕斯卡',
      'filmGrade': '2D 中国巨幕',
      'status': '购票',
      'label': '娄烨巩俐首度合作'
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image8.jpg',
      'name': '五个扑水的少年',
      'score': '9.2',
      'numberOfPeopleToAppraise': '2.4万',
      'director': '宋瀛霖',
      'performer': '辛云来 冯祥坤 李晓谦',
      'filmGrade': '2D IMAX',
      'status': '购票',
      'label': '热血青春全无敌'
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image9.jpg',
      'name': '拯救甜甜圈:时空大营救',
      'score': '8.6',
      'numberOfPeopleToAppraise': '1.2万',
      'director': '大卫·斯沃曼',
      'performer': '宝木中阳 朱蓉蓉',
      'status': '购票',
      'label': '穿越现代拯救族群'
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image10.jpg',
      'name': '皮皮鲁与鲁西西之罐头小人',
      'score': '8.6',
      'numberOfPeopleToAppraise': '2.0万',
      'director': '埃里康·卡萨罗萨',
      'performer': '雅各布·特伦布莱 杰克·迪伦·格雷泽 玛娅·鲁道夫',
      'status': '购票',
      'label': '友谊伴我同行'
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image11.jpg',
      'name': '图兰朵·魔咒缘起',
      'director': '郑晓龙',
      'performer': '关晓彤 迪伦·斯普罗斯',
      'filmGrade': '3D',
      'status': '购票',
      'label': '破解魔咒危机'
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image12.jpg',
      'name': '猪迪克之蓝海奇缘',
      'score': '8.8',
      'numberOfPeopleToAppraise': '7821',
      'director': '杨烨 刘磊',
      'performer': '佟心竹 沈念如 小连杀',
      'status': '购票',
      'label': '海上漂流之旅'
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image13.jpg',
      'name': '大耳朵图图之霸王龙在行动',
      'score': '9.5',
      'numberOfPeopleToAppraise': '2987',
      'director': '速达',
      'status': '购票',
      'label': '在欢笑中成长'
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image14.jpg',
      'name': '深宅迷案',
      'director': '周军',
      'performer': '张济南 王梓霖 隋存毅',
      'filmGrade': '3D',
      'status': '预售',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image15.jpg',
      'name': '峰爆',
      'score': '9.4',
      'numberOfPeopleToAppraise': '37.4万',
      'director': '李俊',
      'performer': '朱一龙 黄志忠 陈数 焦俊艳',
      'filmGrade': '2D IMAX',
      'status': '购票',
      'label': '致敬中国基建人'
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image16.jpg',
      'name': '怒火·重案',
      'score': '8.9',
      'numberOfPeopleToAppraise': '4163',
      'director': '陈木胜',
      'performer': '甄子丹 谢霆锋 秦岚 谭耀文',
      'filmGrade': '2D IMAX',
      'status': '购票',
      'label': '正邪巅峰对决'
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image17.jpg',
      'name': '老鹰抓小鸡',
      'score': '8.8',
      'numberOfPeopleToAppraise': '1.7万',
      'performer': '汤水雨 孟子焱 徐佳琦 任亚明 凌振赫',
      'status': '购票',
      'label': '追寻飞翔之梦'
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image18.jpg',
      'name': '青苔花开',
      'director': '胡静之',
      'performer': '李晔 沈达威 罗玉婷 王晓彤 孙晔',
      'status': '购票',
      'label': '支教老师的坚守'
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image19.jpg',
      'name': '永不消逝的电波(黑白转换)',
      'score': '8.7',
      'numberOfPeopleToAppraise': '16.9万',
      'director': '肖恩·利维',
      'performer': '瑞安·雷诺兹 驻地·科默 里尔·莱尔·哈瓦瑞',
      'filmGrade': '3D IMAX',
      'status': '购票',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image20.jpg',
      'name': '一直游到海水变蓝',
      'director': '伊韦塔·格罗福娃',
      'performer': '瓦妮莎·萨穆赫洛娃 马图斯·巴奇辛',
      'status': '购票',
      'label': '故乡孕育文学'
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image21.jpg',
      'name': '宝可梦:皮卡丘和可可的神奇之旅',
      'score': '9.2',
      'numberOfPeopleToAppraise': '2.3万',
      'director': '陈力',
      'performer': '刘烨 宫哲 侯勇',
      'status': '购票',
      'label': '小人物大情怀',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image22.jpg',
      'name': '悬崖',
      'director': '韩志',
      'performer': '王讯 李易祥 王佳佳 张磊 刘洋 刘超',
      'status': '购票',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image23.jpg',
      'name': '混沌行走',
      'score': '7.2',
      'numberOfPeopleToAppraise': '5498',
      'director': '道格·里曼',
      'performer': '汤姆·赫兰德 黛茜·雷德利 麦斯·米科尔森',
      'status': '购票',
      'label': '荷兰弟主演',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image24.jpg',
      'name': '不期而遇的夏天',
      'score': '8.6',
      'numberOfPeopleToAppraise': '933万',
      'director': '易寒',
      'performer': '陈创 郭可轩 郎月婷 张磊 欧阳招娣',
      'filmGrade': '3D IMAX',
      'status': '购票',
      // 'numberWantSee': '7.0',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image25.jpg',
      'name': '长津湖',
      'numberOfPeopleToAppraise': '414,872',
      'director': '陈凯歌 徐克 林超贤',
      'performer': '吴京 易烊千玺 段奕宏 朱亚文 李晨',
      'filmGrade': '2D IMAX',
      'status': '预售',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image26.jpg',
      'name': '乔西的虎与鱼',
      'score': '8.6',
      'numberOfPeopleToAppraise': '5386',
      'director': '田村耕太郎',
      'performer': '青原果耶 中川大志 兴津和幸 川西肯戈',
      'status': '购票',
      'label': '治愈这个夏天',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image27.jpg',
      'name': '1921',
      'score': '9.2',
      'numberOfPeopleToAppraise': '13.8万',
      'director': '黄建新 郑大圣',
      'performer': '陈坤 埃里克·迪恩 倪大红 刘昊然',
      'filmGrade': '2D IMAX',
      'status': '购票',
      'label': '溯建党初心',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image28.jpg',
      'name': '最后一间房',
      'director': '高博',
      'performer': '宋伊人 倪虹洁 陶慧 周铁 予雷',
      'status': '购票',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image29.jpg',
      'name': '兔子暴力',
      'score': '7.1',
      'numberOfPeopleToAppraise': '9690',
      'director': '申瑜',
      'performer': '万茜 李庚希',
      'status': '购票',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image30.jpg',
      'name': '再见，少年',
      'score': '7.3',
      'numberOfPeopleToAppraise': '7077',
      'director': '殷若昕',
      'performer': '张子枫 张宥浩 徐帆 焦刚',
      // 'filmGrade': '3D IMAX',
      'status': '购票',
      'label': '少年逆风生长',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image25.jpg',
      'name': '我的青春有个你',
      'director': '林子平 孙睿 高炳权',
      'performer': '王可如 刘冬沁 李欢 黄米依 沈腾',
      'status': '购票',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image26.jpg',
      'name': '狼行者',
      'score': '8.8',
      'numberOfPeopleToAppraise': '9559',
      'director': '汤姆·摩尔 罗斯·斯图尔特',
      'performer': '肖恩·宾 霍纳·妮芙茜 西蒙·迈克伯尼 ',
      'status': '购票',
      'label': '高分治愈动画',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image27.jpg',
      'name': '龙虎武师',
      'score': '8.7',
      'numberOfPeopleToAppraise': '1136',
      'director': '魏君子',
      'performer': '洪金宝 程小东 袁和平 甄子丹 徐克 曾志伟',
      'status': '购票',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image28.jpg',
      'name': '你好世界',
      'score': '8.5',
      'numberOfPeopleToAppraise': '6.2万',
      'director': '伊藤智彦',
      'performer': '北村匠海 松阪桃李 滨边美波 子安武人',
      'status': '购票',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image29.jpg',
      'name': '皮皮鲁与鲁西西之罐头小人',
      'director': '洪悦熙',
      'performer': '洪悦熙 庄则熙 田雨 刘一莹',
      'filmGrade': '3D IMAX',
      'status': '购票',
      'numberWantSee': '24,910',
    },
    {
      'imageUrl':
          'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/image30.jpg',
      'name': '保家卫国——抗美援朝光影纪实',
      'score': '9.3',
      'numberOfPeopleToAppraise': '779',
      'director': '郝蕴',
      'performer': '张涵予',
      'status': '购票',
    },
  ];

  @override
  Widget build(BuildContext context) {
    return Column(
      children: [
        Container(
          margin: EdgeInsets.symmetric(horizontal: 5.w, vertical: 10.h),
          padding: EdgeInsets.symmetric(horizontal: 15.w, vertical: 8.h),
          child: Row(
            mainAxisAlignment: MainAxisAlignment.spaceBetween,
            children: [
              Row(
                children: [
                  CachedNetworkImage(
                    imageUrl:
                        'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/real_time.png',
                    fit: BoxFit.fill,
                    width: 15.w,
                    height: 15.w,
                  ),
                  SizedBox(width: 8.w),
                  Text(
                    '实时票房',
                    style: TextStyle(
                        fontSize: 12.sp,
                        color: Colors.black,
                        fontWeight: FontWeight.bold),
                  )
                ],
              ),
              Row(
                mainAxisAlignment: MainAxisAlignment.end,
                children: [
                  Text(
                    '今日大盘',
                    style: TextStyle(
                      fontSize: 12.sp,
                      color: Colors.black,
                    ),
                  ),
                  Text(
                    '6272.5万',
                    style: TextStyle(
                        fontSize: 12.sp,
                        color: Colors.red,
                        fontWeight: FontWeight.bold),
                  ),
                  Icon(Icons.arrow_right)
                ],
              )
            ],
          ),
          decoration: BoxDecoration(
            color: Colors.white,
            borderRadius: BorderRadius.circular(10),
          ),
        ),
        Container(
          margin: EdgeInsets.symmetric(horizontal: 5.w, vertical: 5.w),
          padding: EdgeInsets.symmetric(horizontal: 15.w, vertical: 10.h),
          child: Column(
            mainAxisAlignment: MainAxisAlignment.spaceBetween,
            children: [
              Row(
                mainAxisAlignment: MainAxisAlignment.spaceBetween,
                children: [
                  CachedNetworkImage(
                    imageUrl:
                        'https://amoy-ticket.oss-cn-nanjing.aliyuncs.com/images/movie_one/box_office.png',
                    fit: BoxFit.fill,
                    width: 90.w,
                    height: 18.h,
                  ),
                  Row(
                    children: [
                      Text(
                        '查看完整榜单',
                        style: TextStyle(color: Colors.grey, fontSize: 12.sp),
                      ),
                      Icon(Icons.arrow_right)
                    ],
                  )
                ],
              ),
              Container(
                width: double.infinity,
                height: 30,
                child: Swiper(
                  itemCount: _boxOfficeHeadList.length, // 对象个数
                  loop: true, // 允许循环播放
                  autoplay: true, // 允许自动播放
                  scrollDirection: Axis.vertical, // 滚动方向设置为垂直
                  autoplayDelay: 3000, // 执行时长
                  itemBuilder: (BuildContext context, int index) {
                    return Row(
                      mainAxisAlignment: MainAxisAlignment.spaceBetween,
                      children: [
                        Row(
                          children: [
                            Text(
                              _boxOfficeHeadList[index]['order'],
                              style: TextStyle(
                                  fontSize: 15.sp,
                                  color: (int.parse(_boxOfficeHeadList[index]
                                              ['order']) <
                                          4)
                                      ? Color(0xFFf0953d)
                                      : Colors.grey),
                            ),
                            SizedBox(width: 8.w),
                            Text(
                              _boxOfficeHeadList[index]['name'],
                              style:
                                  TextStyle(fontSize: 15, color: Colors.black),
                            ),
                            SizedBox(width: 5.w),
                            Text('-'),
                          ],
                        ),
                        Row(
                          children: [
                            Text(
                              '近7日票房',
                              style: TextStyle(
                                  fontSize: 12.sp, color: Color(0xFF7a7e88)),
                            ),
                            Text(
                              _boxOfficeHeadList[index]['number'],
                              style: TextStyle(
                                  fontSize: 12.sp, color: Color(0xFFec7e12)),
                            )
                          ],
                        )
                      ],
                    );
                  },
                ),
              )
            ],
          ),
          decoration: BoxDecoration(
            gradient: LinearGradient(
                begin: Alignment.topCenter,
                end: Alignment.bottomCenter,
                stops: [0.0, 1.0],
                colors: [Color(0xFFfdf1d3), Color(0xFFffffff)]),
          ),
        ),
        Expanded(
            child: ListView.builder(
          itemCount: boxOfficeList.length,
          itemBuilder: (context, index) {
            return _itemWidget(
              boxOfficeList[index]?['imageUrl'] ?? '',
              boxOfficeList[index]?['name'] ?? '',
              boxOfficeList[index]?['status'] ?? '',
              director: boxOfficeList[index]?['director'] ?? '',
              performer: boxOfficeList[index]?['performer'] ?? '',
              score: boxOfficeList[index]?['score'] ?? '',
              numberOfPeopleToAppraise:
                  boxOfficeList[index]?['numberOfPeopleToAppraise'] ?? '',
              filmGrade: boxOfficeList[index]?['filmGrade'] ?? '',
              label: boxOfficeList[index]?['label'] ?? '',
              numberWantSee: boxOfficeList[index]?['numberWantSee'] ?? '',
            );
          },
        ))
      ],
    );
  }

  Widget _itemWidget(
    String imageUrl,
    String name,
    String status, {
    String director = '',
    String performer = '',
    String score = '',
    String numberOfPeopleToAppraise = '',
    String filmGrade = '',
    String label = '',
    String numberWantSee = '',
  }) {
    return Container(
      width: double.infinity,
      // height: 100,
      child: Row(
        children: [
          Stack(
            children: [
              Container(
                width: 65.w,
                height: 95.h,
                decoration: BoxDecoration(
                  borderRadius: BorderRadius.circular(5.r),
                  image: DecorationImage(
                    image: CachedNetworkImageProvider(imageUrl),
                    fit: BoxFit.fill,
                  ),
                ),
              ),
              Visibility(
                visible: ObjectUtil.isNotEmpty(filmGrade),
                child: Positioned(
                  left: 2.w,
                  top: 5.h,
                  child: Container(
                    padding:
                        EdgeInsets.symmetric(horizontal: 5.h, vertical: 2.h),
                    decoration: BoxDecoration(
                        color: Colors.black,
                        borderRadius: BorderRadius.circular(5.r)),
                    child: Text(
                      filmGrade,
                      style: TextStyle(
                          color: Colors.white,
                          fontWeight: FontWeight.bold,
                          fontSize: 9.sp),
                    ),
                  ),
                ),
              ),
              Positioned(
                bottom: 5.h,
                right: 5.w,
                child: CircleAvatar(
                  radius: 12.r,
                  backgroundColor: Color(0xFFf6f4f5),
                  child: Icon(
                    Icons.play_arrow,
                    color: Colors.black,
                    size: 17.r,
                  ),
                ),
              ),
            ],
          ),
          SizedBox(width: 15.w),
          Expanded(
            child: Column(
              crossAxisAlignment: CrossAxisAlignment.start,
              children: [
                Text(
                  name,
                  style:
                      TextStyle(fontSize: 14.sp, fontWeight: FontWeight.bold),
                ),
                Visibility(
                  visible: ObjectUtil.isNotEmpty(score),
                  child: Row(
                    children: [
                      Text('淘票票评分 '),
                      SizedBox(width: 4.w),
                      Expanded(
                        child: Text(
                          score,
                          maxLines: 1,
                          style: TextStyle(
                              fontSize: 12.sp,
                              color: Color(0xFFf0953d),
                              fontWeight: FontWeight.bold),
                        ),
                      ),
                      ObjectUtil.isNotEmpty(numberOfPeopleToAppraise)
                          ? Text(
                              '$numberOfPeopleToAppraise人评',
                              style: TextStyle(
                                fontSize: 12.sp,
                                fontWeight: FontWeight.bold,
                              ),
                            )
                          : Container(),
                    ],
                  ),
                ),
                Visibility(
                  visible: ObjectUtil.isNotEmpty(numberWantSee),
                  child: Row(
                    children: [
                      Text(
                        numberWantSee,
                        style: TextStyle(
                            fontSize: 12.sp,
                            color: Color(0xFFf0953d),
                            fontWeight: FontWeight.bold),
                      ),
                      Text('人想看 '),
                      SizedBox(width: 4.w),
                    ],
                  ),
                ),
                Visibility(
                  visible: ObjectUtil.isEmpty(numberWantSee) &&
                      ObjectUtil.isEmpty(score),
                  child: Text('暂无评分'),
                ),
                Row(
                  children: [
                    Text('导演：'),
                    Expanded(
                        child: Text(
                      director,
                      maxLines: 1,
                      overflow: TextOverflow.ellipsis,
                    ))
                  ],
                ),
                Row(
                  children: [
                    Text('主演:'),
                    Expanded(
                      child: Text(
                        performer,
                        maxLines: 1,
                        overflow: TextOverflow.ellipsis,
                      ),
                    )
                  ],
                ),
                SizedBox(height: 10),
                Visibility(
                    visible: ObjectUtil.isNotEmpty(label),
                    child: Container(
                      padding: EdgeInsets.symmetric(horizontal: 2.w),
                      child: Text(label),
                      decoration: BoxDecoration(
                        border: Border.all(color: Colors.grey),
                        borderRadius: BorderRadius.circular(3.r),
                      ),
                    ))
              ],
            ),
          ),
          SizedBox(width: 15.w),
          Center(
            child: Container(
              padding: EdgeInsets.symmetric(horizontal: 12.w, vertical: 5.h),
              child: Text(
                status,
                style: TextStyle(color: Colors.white),
              ),
              decoration: BoxDecoration(
                  color: Colors.pink,
                  borderRadius: BorderRadius.circular(13.r)),
            ),
          ),
        ],
      ),
      padding: EdgeInsets.symmetric(horizontal: 10.w, vertical: 12.h),
      margin: EdgeInsets.only(left: 10.w, right: 10.w, top: 5.h),
      decoration: BoxDecoration(
        color: Colors.white,
        borderRadius: BorderRadius.circular(5.r),
      ),
    );
  }
}
